;;;Rescale occurances of a block about insertion points.
;;;
;;;	AUTHOR: Henry C. Francis
;;;		425 N. Ashe St.
;;;		Southern Pines, NC 28387
;;;		All rights reserved without prejudice.
;;;
;;;	Copyright:	12-22-94
;;;	Edited:		3-17-95
;;;	Edited:		12-6-2007 autoloads UREAL and USTR if not loaded
;;;
(DEFUN C:BS ( / tht tset tsln cntr tent edtw)
(setq osmde (getvar"osmode"))
(setvar "osmode" 0)
(if ureal nil (load "ureal" "\nFile UREAL.LSP not loaded! "))
(if ustr nil (load "ustr" "\nFile USTR.LSP not loaded! "))
(setq bscl (ureal 1 "" "\nScale Factor: " (if bscl bscl 1)))
(setq blkol (ustr 1 "Block Name? " (if blkol blkol "point") nil))
(if (eq (strcase blkol) "AECC_POINT")
  (setq getit (strcat "((0 . \"" (eval blkol) "\"))"))
  (setq getit (strcat "((-4 . \"<and\")(0 . \"INSERT\")(2 . \"" (eval blkol) "\")(-4 . \"and>\"))"))
)
(setq tset (ssget (read getit)))
(if tset
  (progn
    (setq tsln (sslength tset))
    (setq cntr 0)
  );progn
);if
(while
  (if (and (< cntr tsln) tset)
    (setq tent (entget (ssname tset cntr)))
  );if
  (progn
    (setq edtw (entget (cdar tent)))
    (setq inxyz (trans(cdr(assoc 10 edtw)) 0 1))
    (command ".scale" (cdar edtw) "" inxyz bscl)
    (setq cntr (1+ cntr))
  );progn
);while
(setvar "osmode" osmde)
(princ)
);DEFUN
